class CreateInstallations < ActiveRecord::Migration
  def self.up
    create_table :installations do |t|
      t.string :install_no
      t.date :installed_on
      t.decimal :should_be_payed_price,
        :payed_price,
        :precision => 8, :scale => 2      
      t.integer :order_id,
        :installer_id,
        :creator_id
      t.string :status, :default => 'being_edited'
      t.timestamp :edited_at,
        :effected_at,
        :blanked_out_at
      t.text :remark
      t.timestamps
    end
  end

  def self.down
    drop_table :installations
  end
end
